// 1.创建类 class 创建一个
class Person {
    constructor(name, age) {
        this.name = name;
        this.age = age;
    }
}

// 2.利用类创建对象 new
var self = new Person('llhuang10', 18);

console.log(self);  // Person { name: 'llhuang10', age: 18 }

// console.log(1);
// setTimeout(function () {
//     console.log(3);
// }, 1000);
// console.log(2);

console.log('---------------')
console.log(1);
setTimeout(function () {
    console.log(3);
}, 0);
console.log(2);
